package com.mvc.framework.handler;

import java.lang.reflect.Method;
import java.util.regex.Pattern;

/**
	 * HandlerMapping 定义
	 * 
	 * @author Tom
	 *
	 */
public class Handler {

	private Object controller;
	private Method method;
	private Pattern pattern;

	public Handler(Pattern pattern, Object controller, Method method) {
		this.pattern = pattern;
		this.controller = controller;
		this.method = method;
	}

	public Object getController() {
		return controller;
	}

	public void setController(Object controller) {
		this.controller = controller;
	}

	public Method getMethod() {
		return method;
	}

	public void setMethod(Method method) {
		this.method = method;
	}

	public Pattern getPattern() {
		return pattern;
	}

	public void setPattern(Pattern pattern) {
		this.pattern = pattern;
	}

	@Override
	public String toString() {
		return "Handler [controller=" + controller + ", method=" + method + ", pattern=" + pattern + "]";
	}

}